<?php
class Type extends CI_Model {
	function __construct() {
		parent::__construct ();
	}
	function getType($type) {
		$this->db->select ( 'id_Type' );
		$this->db->from ( 'type' );
		$this->db->where ( 'type', $type );
		$query = $this->db->get ();
		if ($query->num_rows () == 1) {
			return $query->result ();
		} else {
			return false;
		}
	}
}